package com.ld.wms.business.log.controller;


import com.ld.wms.business.log.service.LockerEnvironmentLogService;
import com.ld.wms.business.log.vo.resp.InventoryOperateLogRespVo;
import com.ld.wms.business.log.vo.resp.LockerEnvironmentLogRespVo;
import com.ld.wms.common.ResultResponse;
import com.ld.wms.common.vo.GeneratePageListVo;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 柜体环境日志 前端控制器
 * </p>
 *
 * @author wangfeng
 * @since 2025-05-06
 */
@Slf4j
@Tag(name = "柜体环境日志相关接口")
@RestController
public class LockerEnvironmentLogController {

    @Autowired
    private LockerEnvironmentLogService lockerEnvironmentLogService;

    @GetMapping("/api/wms/lockerEnvironmentLog/getPageList")
    @Operation(summary = "柜体环境日志列表)")
    public ResultResponse<GeneratePageListVo<LockerEnvironmentLogRespVo>> getPageList(
            @Parameter(description = "当前页数") @RequestParam(defaultValue = "1") Integer current,
            @Parameter(description = "每页展示条数") @RequestParam(defaultValue = "10") Integer size
    ) {
        GeneratePageListVo<LockerEnvironmentLogRespVo> pageList = lockerEnvironmentLogService.getPageList(current, size);
        return ResultResponse.success(pageList);
    }
}

